import { createApp } from 'vue'
import App from './App.vue'
import router from './router'
import store from './store'
import ElementPlus from 'element-plus'
import 'element-plus/dist/index.css'
import * as ElementPlusIconsVue from '@element-plus/icons-vue'
import Antd from 'ant-design-vue'
import { DownOutlined } from '@ant-design/icons-vue'
import 'ant-design-vue/dist/antd.css'
import './assets/styles/global.css'

// 创建应用实例
const app = createApp(App)

// 注册Element Plus图标
for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
  app.component(key, component)
}

// 注册Ant Design图标
app.component('DownOutlined', DownOutlined)

// 使用插件
app.use(store)
  .use(router)
  .use(Antd)
  .use(ElementPlus)
  .mount('#app')
